-
Notifications
You must be signed in to change notification settings - Fork 273
Error handling cleanup in solvers/flattening 5 #2938
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error handling cleanup in solvers/flattening 5 #2938
Conversation
|
||
bvtypet bvtype=get_bvtype(type); | ||
bvtypet op_bvtype=get_bvtype(op0.type()); | ||
std::size_t op_width=op_bv.size(); | ||
bvtypet op_bvtype = get_bvtype(op.type()); | ||
|
||
bool no_overflow=(expr.id()=="no-overflow-unary-minus"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"no-overflow-unary-minus"
does not seem to be assigned anywhere. Is this still needed?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@peterschrammel Do you know if we can remove "no-overflow-unary-minus"?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Passed Diffblue compatibility checks (cbmc commit: baec7a1).
Build URL: https://travis-ci.com/diffblue/test-gen/builds/84576476
@@ -96,7 +85,7 @@ bvt boolbvt::convert_unary_minus(const unary_exprt &expr) | |||
} | |||
else if(bvtype==bvtypet::IS_FLOAT && op_bvtype==bvtypet::IS_FLOAT) | |||
{ | |||
assert(!no_overflow); | |||
INVARIANT(!no_overflow, ""); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
missing message
|
||
bvt tmp_result; | ||
const auto sub_it = std::next(op_bv.begin(), sub_idx); | ||
std::copy_n(sub_it, sub_width, std::back_inserter(tmp_op)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm sure this is a good idea, but seems unrelated to the goal of the commit?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, this has become a separate commit now.
f59eb53
to
a86fbea
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Failing unit test:
java_bytecode/ci_lazy_methods/lazy_load_lambdas.cpp:17
with
Invariant check failed
File: std_types.h:1319 function: validate_type
Condition: signed bitvector type must have non-zero width
Reason: type.get_width() > 0
a86fbea
to
8c31e83
Compare
8c31e83
to
7d629c5
Compare
@tautschnig I've removed those additional checks |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Passed Diffblue compatibility checks (cbmc commit: 7d629c5).
Build URL: https://travis-ci.com/diffblue/test-gen/builds/86032809
No description provided.